package com.gxuwz.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.gxuwz.core.util.SystemContext;
import com.gxuwz.dao.impl.SysUserRoleDao;
import com.gxuwz.pojo.SysUserRole;
import com.gxuwz.pojo.SysUserRole;
import com.gxuwz.service.ISysUserRoleService;

@Service("sysUserRoleService")
public class SysUserRoleServiceImpl implements ISysUserRoleService {

	@Autowired
	private SysUserRoleDao sysUserRoleDao;

	@Override
	public List<SysUserRole> list(SysUserRole entity) {
		// TODO Auto-generated method stub
		return sysUserRoleDao.findByEntity(entity);
	}

	@Override
	public SysUserRole save(SysUserRole entity) {
		// TODO Auto-generated method stub
		return sysUserRoleDao.save(entity);
	}

	@Override
	public void remove(SysUserRole entity) {
		// TODO Auto-generated method stub
		sysUserRoleDao.remove(entity);
	}

	@Override
	public void update(SysUserRole entity) {
		// TODO Auto-generated method stub
		sysUserRoleDao.update(entity);
	}

	@Override
	public List<SysUserRole> findByHql(String queryString, Object[] params) {
		// TODO Auto-generated method stub
		return sysUserRoleDao.findByHql(queryString, params);
	}

	@Override
	public List<SysUserRole> findByExample(Object exampleEntity) {
		// TODO Auto-generated method stub
		return sysUserRoleDao.findByExample(exampleEntity);
	}

	@Override
	public List<SysUserRole> findByEntity(SysUserRole entity) {
		// TODO Auto-generated method stub
		return sysUserRoleDao.findByEntity(entity);
	}

	@Override
	public SysUserRole findById(Integer id) {
		// TODO Auto-generated method stub
		return sysUserRoleDao.find("form SysUserRole where id="+id).get(0);
	}

	@Override
	public List<SysUserRole> findByProperty(String property, String value) {
		// TODO Auto-generated method stub
		return sysUserRoleDao.findByProperty(property, value);
	}


}
